<?php
include_once(EC_PATH . '/includes/lib_transaction.php');

($order_id = _POST('order_id', 0)) || abort('参数错误!');

($user_id = session('user_id')) || abort('请先登录!');

/* 订单详情 */
$order = get_order_detail($order_id, $user_id);

return [
    'alipay' => [
        'Notify_Url' 	    => $ecs->url().'pay/return_url.php',
        'PARTNER'			=> '2088122012152804',
        'RSA_PRIVATE'	    => base64_encode('MIIEpQIBAAKCAQEAx5TbGgfTriQgxIOvDNBQjEHDrXAnRc8RpS4Gr5KTR2SoksbkJIh59ILlgWVYkhr6tmcvzNboUefl7j1rlHFBOi+PzTKhMctt33LzA1bvRiHbIouxflKgUFnkF7R0VTgeRvTOhgEu7sPMxC/vVSEh5FRBII03fTatUdI6WHkwpDGAXXUhzlr3987m6pAuPBccDL7KGin7hx3Jv2yDPZx92PzCIB3Z6hZviJq6HMKRTTXEq/yoY56ELYvfUnQ409wI85C3JU1rUmpTJlawFE9sbw0RwVJnNKhAmrgMG1hFTZWLfRWsUDlvv0w8KCVqGHFj2KRx5DZi6dpLoPsz7jwPwQIDAQABAoIBAQDAaat+ghM7bUtGCiqmsOMnBXQwbtL+A29gj2oUtLxW9R1sPGHRMt5YtCWtxVZJrccOOZck5gAejvLm58Ii37lh7l62Fty/U/++kGTnUFXoiFVrDcB2KBS0wqUbkXcifbL696NwIA3uVUjBz/DuYr35Ep2jU2Iuzpr0Kjjj+RrC/95qtspElOrmzDM4vveYy+cxeAKBjCI1xl35eA3nSHo3OxIjudll2nO4Jy//a+5YF4ezzj92Rj6oV2EDcTRWbs5VL9diopRTHUC44Xfkpzr6f8WSRQ8emmUv1shDcY92LFHJo+Fjh6tLvCB8N8R77kSr8367P4Sf4f9xOz+R5we9AoGBAOdaANGHeBW1QbsUaRXWusjqznxFnnAtSBwW1SocfQx5YddpZlfaPRWWMuOYlWM4q61nTq3+P/mihuSp9Jby2mqSwaJX0xp//vkSFpxgvN0HLv8Hz5ntJmNadbeZZXay45LsQ9RHaG7x9fsHxMzBg9XszT5rLSGYwybT+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kLuA5fNXdj0wsgXhN/sHDOwP6o8vj1q4YaqXs0bUYRHwIDAQAB'),
        'SELLER'			=> $GLOBALS['_CFG']['shop_name'],
        'allcost'			=> $order['order_amount'],
        'orderid'			=> $order['order_sn'],
        'paytype'			=> 'alipay',
        'support'			=> 1,
        'wmrid'				=> $order['order_id']
    ],
    'allcost'   => $order['order_amount'],
    'plate' 	=> [
        'acountcost'    => $order['order_amount'],
        'support'       => 1
    ],
    'titlename' => "商品付款"
];

//-------------------------------------------------------------------------------------------------------
return [
    'alipay' => [
        'Notify_Url' 	=> $ecs->url().'app/pay/return_url.php',
        'PARTNER'			=> '2088122012152804',
        // 'RSA_PRIVATE'	=> 'MIIEogIBAAKCAQEAolsroD3YLEMv9PTKaRcEfyZPFiyMEM0/rACUakf9srx7mi+7
        // u5xnKi1OOcMiUZnTtqxMI8rnSues81Id64aeuoGISp4eUVdT3C8GWvl+XixCrkp9
        // 59REF59Q5elpuukdgh/6+MtlRSVEnGKKVQkmet0RArQ8OA+lMF51D4u8sb+EoEyd
        // M63wmOpHH7pmUbsJ5zxgcHGoz1oxJxAWdo7Kh3NT5bi8SQCmkt2j5LKBOe+S5Ui6
        // VtI7vjZ3kr4NtXAIkBPlQ0zKe4CL7dGzelJuXb495VNeIOcrbYyFFsoPGer/vkeT
        // eHy4lDqpTKcwI/0P5i5SWToJQnMKssUppEhIgQIDAQABAoIBAClcgKi6GLBuDXGi
        // S06qhoK+B7fmcWh2YZo4K5dH7+HxEqwdLP6GweGE2UDt7XhMcBtBmcQklPgIPY9f
        // hC/Ug+uPxGD+F0sxrDOT51KV7ROgwvwUDi9ZbF94PuvToxPy/4l/DDkF2C7dZ7VP
        // hV5UjnEOkJ7Xu9+sXLEN31SujMvbTs5LL/LFZQgT3i7ygjC/DvarXxoj2ZgmIb1w
        // n7OFQtVn5iudzvw40Y4/QYYRG6zTXxwOrZ4BHWMegAKSQUP1W9UCuKFpuvsCJ1Dw
        // 2T030BNd48Of6HJRK4pu305zKsuaEhDLdz0K4fyDFW8L1wWl7VX5o7cDU8snbylt
        // j3MzgoECgYEA0Nq1aDxnHLQhTpA+zgz6hH0RUQ80gN1ug+4pj0oU7BfnAQukYNC6
        // 7gqJGqoo973lWvYXVmnUa/4K+UDIWJoDejgrPwLDEWIwCQ7ZJE8InEiaLoZu0TkG
        // 7yNlLzq64+vK31yEpweOzavRgwu1W0aualDCiqvxTp3EUYcfn93fbA0CgYEAxwFr
        // kL/+8xbRdiAX2fd0WedfWWJrlqY9tcEFe7PSNlhSnd5PzzvNTHrTIQFV3mZXzfYY
        // liVvtuhYGF6uoEgYSfuwA8gLrfyISal8opRlN1q4/NM+pWeLYoFwK9OuH0z2VXOV
        // 58WoYcdWG03OCw8n1tW2dN5dSyo22FBfmy6BjUUCgYA6dX1hd8bE2gaYnvd1ZVyZ
        // yQgX0FG54EEW3Ir1eJ7ylp4qRL/1+XbZOkm2FPrynUydcVSG84hp0enwapmpczKV
        // +zLfqD5Bl2IqpuVQrG6UkB3X9/j8xyGRvi6MUbwOH+nhK1xWBF+MYhN6wsQ4kEgx
        // qflKJ2abwr04tMG9VbU74QKBgD3KXhjS1JmsIxuXeXBvWkw0ADIj0h4zvgN6THaN
        // bh77q6NjDMre2a7+kCG2ZXApvOexmw67zwUu/XOLqpMP76LBKHT0H1RFjhe5LX7Z
        // rtfSLpAqE1COZwQOBsNE9dK4NeBwhEIz6EV7/Gt77BcY/JjDQOTmynb1Q5RE2Hq5
        // pPY1AoGALCRwYsacuIcW8WjiiC34saE6RZ4yqTsVXQ1GaYYhP98wq99d5zmqsP8n
        // c1HZwzKkTP/TWotVKogsqFxFe21BqtyTtTscYcnasM9rAJzrq5AmrvcJatmOf77m
        // cxaNtLL9ILK1XmwN4KdMqWKWOt3jSH/oAuTF4yQkMc6OYayjt8M=',
        //'RSA_PUBLIC'	=> 'AAAAB3NzaC1yc2EAAAADAQABAAABAQCiWyugPdgsQy/09MppFwR/Jk8WLIwQzT+sAJRqR/2yvHuaL7u7nGcqLU45wyJRmdO2rEwjyudK56zzUh3rhp66gYhKnh5RV1PcLwZa+X5eLEKuSn3n1EQXn1Dl6Wm66R2CH/r4y2VFJUScYopVCSZ63RECtDw4D6UwXnUPi7yxv4SgTJ0zrfCY6kcfumZRuwnnPGBwcajPWjEnEBZ2jsqHc1PluLxJAKaS3aPksoE575LlSLpW0ju+NneSvg21cAiQE+VDTMp7gIvt0bN6Um5dvj3lU14g5yttjIUWyg8Z6v++R5N4fLiUOqlMpzAj/Q/mLlJZOglCcwqyxSmkSEiB',
        //'RSA_PRIVATE'	=> file_get_contents(EC_PATH.'/cre/1024/app_private_key.pem'),
        // 'RSA_PRIVATE'	=> base64_encode('MIIEpgIBAAKCAQEA4I3jtgy8Cq3iee0u/yXYyslKG5oI67zU1tXjBGNTS/y/vxFxan3BLJojHv8qpdv4+u4AeM36SkSRCcTJYfexe2CdhL+1tuPBPgUcoTNn+mwE4b5PCyC9XZJ0EZfcRIc8oMRuS4Ga5NSbmLKgqV8ewmgvIRzBzsaigPBb+hmcxao3wik1Ct/Bh7QuZcJaNoUaE6R4fZSLKKBG1Xs3DzVTHJAIbD34voS9CCEj++w6aHfLanmixNjboDIBG8xE4Osfuec8EDLpwN2ir8VulpUHjpYsXqGO1fbTlmp1JuQtAOkLuA5fNXdj0wsgXhN/sHDOwP6o8vj1q4YaqXs0bUYRHwIDAQABAoIBAQC4/kvVg+I6jgwhVHQ+QQi77159JMYqp3NU1fpjeAx8cmnpV85u49EMFKPQenjBEVqqJv7+hvqmypwORy985RkzQmIipelnFXTyyjVO3FHR7cGL1EO8MCmxd+DlSY1ua1dYPtt6mvhngnv5LVfMkQ9/K2OATPehiOUBgoLTpNwRvmGJwo5ltrd7URGLUO6nsGP96TkEOxhs25NZpuBYqtXwdpdz1SFhJLit6xqfUZiFl9TPj3EXuXSGy939VP0aoUioPnavHPIdvKDw3ESetp9bftkxnq8HsW4UOM8EcRFN5H5MjtIbN8nQehsvtHxRDe8IwMCpgqbsPGH3DmtR93bhA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Xx68o71aXLhLSirLgHSddYlYek2CVzTtVo722qdZvaBOmUfoFRagLZHslEbSRgoHP0fWjW1snRH50As8H51Fy9yvxEXcKzi2a/2am8UqWkZAz/HJUDdnIjHTJvKWpNkCgYEAvZjY0+LvbbNrIyf7hw4C7HGT6R/aCNbYWHD6wpzBrWfnLPES/bBoZ26WzFI8fafxkP7QN19f7UhQoTHeHK0OFFZUvFMEX1QKeZmNsvZBT18ydfAMzVJPSE/Vjbcx8oiI4MK6o/7119Rvmo8pQtaG0CFRwJm2qgbOpMG4hmwWp6g='),
        //'RSA_PUBLIC'  => file_get_contents(EC_PATH.'/cre/1024/app_public_key.pem'),
        'RSA_PUBLIC'  => base64_encode('MIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEA4I3jtgy8Cq3iee0u/yXYyslKG5oI67zU1tXjBGNTS/y/vxFxan3BLJojHv8qpdv4+u4AeM36SkSRCcTJYfexe2CdhL+1tuPBPgUcoTNn+mwE4b5PCyC9XZJ0EZfcRIc8oMRuS4Ga5NSbmLKgqV8ewmgvIRzBzsaigPBb+hmcxao3wik1Ct/Bh7QuZcJaNoUaE6R4fZSLKKBG1Xs3DzVTHJAIbD34voS9CCEj++w6aHfLanmixNjboDIBG8xE4Osfuec8EDLpwN2ir8VulpUHjpYsXqGO1fbTlmp1JuQtAOkLuA5fNXdj0wsgXhN/sHDOwP6o8vj1q4YaqXs0bUYRHwIDAQAB'),
        'SELLER'			=> 'aoyun@aoyun.com',
        'allcost'			=> '0.01',
        'orderid'			=> 'O'.date('YmdHis'),
        'paytype'			=> 'order',
        'support'			=> 1,
        'wmrid'				=> 101835
    ],
    'allcost' => '0.01',
    'plate' 	=> [
        'acountcost' => '0.01',
        'support' => 1
    ],
    'titlename' => "商品付款"
];
//------------------------------------------------------------------------------------------------------